package com.nkzy.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@Controller
public class PageController {
    //当路径变量名称和参数名一样时，@PathVariable中的value可以省略
    @GetMapping("/{page}")
    public String showPage(@PathVariable String page){
        return page;
    }
}
